//
// Created by wkm on 2024-04-22.
//

#include "schedulekey_test.h"

void schedulekey_test() {
    sc_clock clk("myclk", 2, sc_core::SC_NS);
    sc_signal<bool> reset, start;
    sc_signal<exe_state> done, can_read;
    sc_signal<sc_uint<4>> get_round; //获取第几轮的密钥
    sc_signal<sc_uint<DATA_SIZE>> init_key_1, init_key_2, init_key_3, init_key_4,
            init_key_5, init_key_6, init_key_7, init_key_8,
            init_key_9, init_key_10, init_key_11, init_key_12,
            init_key_13, init_key_14, init_key_15, init_key_16;
    sc_signal<sc_uint<DATA_SIZE>> out_key_1, out_key_2, out_key_3, out_key_4,
            out_key_5, out_key_6, out_key_7, out_key_8,
            out_key_9, out_key_10, out_key_11, out_key_12,
            out_key_13, out_key_14, out_key_15, out_key_16;

    schedulekey my_schedulekey("my_schedulekey");
    my_schedulekey.clk(clk);
    my_schedulekey.start(start);
    my_schedulekey.reset(reset);
    my_schedulekey.done(done);
    my_schedulekey.can_read(can_read);
    my_schedulekey.get_round(get_round);
    my_schedulekey.init_key_1(init_key_1);
    my_schedulekey.init_key_2(init_key_2);
    my_schedulekey.init_key_3(init_key_3);
    my_schedulekey.init_key_4(init_key_4);
    my_schedulekey.init_key_5(init_key_5);
    my_schedulekey.init_key_6(init_key_6);
    my_schedulekey.init_key_7(init_key_7);
    my_schedulekey.init_key_8(init_key_8);
    my_schedulekey.init_key_9(init_key_9);
    my_schedulekey.init_key_10(init_key_10);
    my_schedulekey.init_key_11(init_key_11);
    my_schedulekey.init_key_12(init_key_12);
    my_schedulekey.init_key_13(init_key_13);
    my_schedulekey.init_key_14(init_key_14);
    my_schedulekey.init_key_15(init_key_15);
    my_schedulekey.init_key_16(init_key_16);
    my_schedulekey.out_key_1(out_key_1);
    my_schedulekey.out_key_2(out_key_2);
    my_schedulekey.out_key_3(out_key_3);
    my_schedulekey.out_key_4(out_key_4);
    my_schedulekey.out_key_5(out_key_5);
    my_schedulekey.out_key_6(out_key_6);
    my_schedulekey.out_key_7(out_key_7);
    my_schedulekey.out_key_8(out_key_8);
    my_schedulekey.out_key_9(out_key_9);
    my_schedulekey.out_key_10(out_key_10);
    my_schedulekey.out_key_11(out_key_11);
    my_schedulekey.out_key_12(out_key_12);
    my_schedulekey.out_key_13(out_key_13);
    my_schedulekey.out_key_14(out_key_14);
    my_schedulekey.out_key_15(out_key_15);
    my_schedulekey.out_key_16(out_key_16);

    schedulekey_driver my_schedulekey_driver("my_schedulekey_driver");
    my_schedulekey_driver.d_clk(clk);
    my_schedulekey_driver.d_reset(reset);
    my_schedulekey_driver.d_start(start);
    my_schedulekey_driver.get_round(get_round);
    my_schedulekey_driver.d_init_key_1(init_key_1);
    my_schedulekey_driver.d_init_key_2(init_key_2);
    my_schedulekey_driver.d_init_key_3(init_key_3);
    my_schedulekey_driver.d_init_key_4(init_key_4);
    my_schedulekey_driver.d_init_key_5(init_key_5);
    my_schedulekey_driver.d_init_key_6(init_key_6);
    my_schedulekey_driver.d_init_key_7(init_key_7);
    my_schedulekey_driver.d_init_key_8(init_key_8);
    my_schedulekey_driver.d_init_key_9(init_key_9);
    my_schedulekey_driver.d_init_key_10(init_key_10);
    my_schedulekey_driver.d_init_key_11(init_key_11);
    my_schedulekey_driver.d_init_key_12(init_key_12);
    my_schedulekey_driver.d_init_key_13(init_key_13);
    my_schedulekey_driver.d_init_key_14(init_key_14);
    my_schedulekey_driver.d_init_key_15(init_key_15);
    my_schedulekey_driver.d_init_key_16(init_key_16);

    schedulekey_monitor my_schedulekey_monitor("my_schedulekey_monitor");
    my_schedulekey_monitor.m_done(done);
    my_schedulekey_monitor.m_can_read(can_read);
    my_schedulekey_monitor.m_out_key_1(out_key_1);
    my_schedulekey_monitor.m_out_key_2(out_key_2);
    my_schedulekey_monitor.m_out_key_3(out_key_3);
    my_schedulekey_monitor.m_out_key_4(out_key_4);
    my_schedulekey_monitor.m_out_key_5(out_key_5);
    my_schedulekey_monitor.m_out_key_6(out_key_6);
    my_schedulekey_monitor.m_out_key_7(out_key_7);
    my_schedulekey_monitor.m_out_key_8(out_key_8);
    my_schedulekey_monitor.m_out_key_9(out_key_9);
    my_schedulekey_monitor.m_out_key_10(out_key_10);
    my_schedulekey_monitor.m_out_key_11(out_key_11);
    my_schedulekey_monitor.m_out_key_12(out_key_12);
    my_schedulekey_monitor.m_out_key_13(out_key_13);
    my_schedulekey_monitor.m_out_key_14(out_key_14);
    my_schedulekey_monitor.m_out_key_15(out_key_15);
    my_schedulekey_monitor.m_out_key_16(out_key_16);

    sc_start();
}